<template>
<div>
  <h2>Movie</h2>
  <p>{{$store.state.num}}</p>
  <p>{{$store.getters.doubleNum}}</p>
  <button @click="incrementWait">延迟1秒加一</button>
  <button @click="incrementNWait({n:2})">延迟1秒加n</button>
  <button @click="getMovieList">获取电影列表</button>
  <ul>
    <li v-for="item in moveList" :key="item.tvId">
      {{item.name}}
    </li>
  </ul>
</div>
</template>


<script>
import {mapActions,mapState} from "vuex"
export default {
  name:"Movie",
  methods:{
    ...mapActions("Count",["incrementWait","incrementNWait"]),
    ...mapActions("Movie",["getMovieList"])
  },
  computed:{
    ...mapState("Movie",["moveList"])
  }

}
</script>


<style></style>